home *** CD-ROM | disk | FTP | other *** search
/ Apple WWDC 1996 / WWDC96_1996 (CD).toast / Technology Materials / MacOS 8 Resources / Developer Tools / Mac OS 8 Interfaces & Libraries / Interfaces / CIncludes / Collections.h < prev    next >
C/C++ Source or Header  |  1996-05-01  |  18KB  |  469 lines

  1. /*
  2.      File:        Collections.h
  3.  
  4.      Contains:    Collection Manager Interfaces
  5.  
  6.      Version:    Technology:    Copland
  7.                  Release:    Universal Interfaces 3.0d3 on Copland DR1
  8.  
  9.      Copyright:    © 1984-1996 by Apple Computer, Inc.  All rights reserved.
  10.  
  11.      Bugs?:        If you find a problem with this file, send the file and version
  12.                  information (from above) and the problem description to:
  13.  
  14.                      Internet:    apple.bugs@applelink.apple.com
  15.                      AppleLink:    APPLE.BUGS
  16.  
  17. */
  18. #ifndef __COLLECTIONS__
  19. #define __COLLECTIONS__
  20.  
  21. #ifndef __TYPES__
  22. #include <Types.h>
  23. #endif
  24. #ifndef __MIXEDMODE__
  25. #include <MixedMode.h>
  26. #endif
  27. #ifndef __MEMALLOCATORS__
  28. #include <MemAllocators.h>
  29. #endif
  30.  
  31. #ifdef __cplusplus
  32. extern "C" {
  33. #endif
  34.  
  35. #if PRAGMA_IMPORT_SUPPORTED
  36. #pragma import on
  37. #endif
  38.  
  39. #if PRAGMA_ALIGN_SUPPORTED
  40. #pragma options align=mac68k
  41. #endif
  42.  
  43. /*************/
  44. /* Constants */
  45. /*************/
  46. /* Convenience constants for functions which optionally return values */
  47.  
  48. enum {
  49.     kCollectionDontWantTag        = 0L,
  50.     kCollectionDontWantId        = 0L,
  51.     kCollectionDontWantSize        = 0L,
  52.     kCollectionDontWantAttributes = 0L,
  53.     kCollectionDontWantIndex    = 0L,
  54.     kCollectionDontWantData        = 0L
  55. };
  56.  
  57. /* attributes bits */
  58.  
  59. enum {
  60.     kCollectionNoAttributes        = 0x00000000,                    /* no attributes bits set */
  61.     kCollectionAllAttributes    = 0xFFFFFFFF,                    /* all attributes bits set */
  62.     kCollectionUserAttributes    = 0x0000FFFF,                    /* user attributes bits */
  63.     kCollectionDefaultAttributes = 0x40000000                    /* default attributes - unlocked, persistent */
  64. };
  65.  
  66. /*
  67.     Attribute bits 0 through 15 (entire low word) are reserved for use by the application.
  68.     Attribute bits 16 through 31 (entire high word) are reserved for use by the Collection Manager.
  69.     Only bits 31 (kCollectionLockBit) and 30 (kCollectionPersistenceBit) currently have meaning.
  70. */
  71.  
  72. enum {
  73.     kCollectionUser0Bit            = 0,
  74.     kCollectionUser1Bit            = 1,
  75.     kCollectionUser2Bit            = 2,
  76.     kCollectionUser3Bit            = 3,
  77.     kCollectionUser4Bit            = 4,
  78.     kCollectionUser5Bit            = 5,
  79.     kCollectionUser6Bit            = 6,
  80.     kCollectionUser7Bit            = 7,
  81.     kCollectionUser8Bit            = 8,
  82.     kCollectionUser9Bit            = 9,
  83.     kCollectionUser10Bit        = 10,
  84.     kCollectionUser11Bit        = 11,
  85.     kCollectionUser12Bit        = 12,
  86.     kCollectionUser13Bit        = 13,
  87.     kCollectionUser14Bit        = 14,
  88.     kCollectionUser15Bit        = 15,
  89.     kCollectionReserved0Bit        = 16,
  90.     kCollectionReserved1Bit        = 17,
  91.     kCollectionReserved2Bit        = 18,
  92.     kCollectionReserved3Bit        = 19,
  93.     kCollectionReserved4Bit        = 20,
  94.     kCollectionReserved5Bit        = 21,
  95.     kCollectionReserved6Bit        = 22,
  96.     kCollectionReserved7Bit        = 23,
  97.     kCollectionReserved8Bit        = 24,
  98.     kCollectionReserved9Bit        = 25,
  99.     kCollectionReserved10Bit    = 26,
  100.     kCollectionReserved11Bit    = 27,
  101.     kCollectionReserved12Bit    = 28,
  102.     kCollectionReserved13Bit    = 29,
  103.     kCollectionPersistenceBit    = 30,
  104.     kCollectionLockBit            = 31
  105. };
  106.  
  107. /* attribute masks */
  108.  
  109. enum {
  110.     kCollectionUser0Mask        = 1L << kCollectionUser0Bit,
  111.     kCollectionUser1Mask        = 1L << kCollectionUser1Bit,
  112.     kCollectionUser2Mask        = 1L << kCollectionUser2Bit,
  113.     kCollectionUser3Mask        = 1L << kCollectionUser3Bit,
  114.     kCollectionUser4Mask        = 1L << kCollectionUser4Bit,
  115.     kCollectionUser5Mask        = 1L << kCollectionUser5Bit,
  116.     kCollectionUser6Mask        = 1L << kCollectionUser6Bit,
  117.     kCollectionUser7Mask        = 1L << kCollectionUser7Bit,
  118.     kCollectionUser8Mask        = 1L << kCollectionUser8Bit,
  119.     kCollectionUser9Mask        = 1L << kCollectionUser9Bit,
  120.     kCollectionUser10Mask        = 1L << kCollectionUser10Bit,
  121.     kCollectionUser11Mask        = 1L << kCollectionUser11Bit,
  122.     kCollectionUser12Mask        = 1L << kCollectionUser12Bit,
  123.     kCollectionUser13Mask        = 1L << kCollectionUser13Bit,
  124.     kCollectionUser14Mask        = 1L << kCollectionUser14Bit,
  125.     kCollectionUser15Mask        = 1L << kCollectionUser15Bit,
  126.     kCollectionReserved0Mask    = 1L << kCollectionReserved0Bit,
  127.     kCollectionReserved1Mask    = 1L << kCollectionReserved1Bit,
  128.     kCollectionReserved2Mask    = 1L << kCollectionReserved2Bit,
  129.     kCollectionReserved3Mask    = 1L << kCollectionReserved3Bit,
  130.     kCollectionReserved4Mask    = 1L << kCollectionReserved4Bit,
  131.     kCollectionReserved5Mask    = 1L << kCollectionReserved5Bit,
  132.     kCollectionReserved6Mask    = 1L << kCollectionReserved6Bit,
  133.     kCollectionReserved7Mask    = 1L << kCollectionReserved7Bit,
  134.     kCollectionReserved8Mask    = 1L << kCollectionReserved8Bit,
  135.     kCollectionReserved9Mask    = 1L << kCollectionReserved9Bit,
  136.     kCollectionReserved10Mask    = 1L << kCollectionReserved10Bit,
  137.     kCollectionReserved11Mask    = 1L << kCollectionReserved11Bit,
  138.     kCollectionReserved12Mask    = 1L << kCollectionReserved12Bit,
  139.     kCollectionReserved13Mask    = 1L << kCollectionReserved13Bit,
  140.     kCollectionPersistenceMask    = 1L << kCollectionPersistenceBit,
  141.     kCollectionLockMask            = 1L << kCollectionLockBit
  142. };
  143.  
  144. /***********/
  145. /* Types   */
  146. /***********/
  147. /* abstract data type for a collection */
  148. typedef struct OpaqueCollection* Collection;
  149. /* collection member 4 byte tag */
  150. typedef FourCharCode CollectionTag;
  151. #if FOR_SYSTEM7_AND_SYSTEM8_COOPERATIVE
  152. typedef pascal OSErr (*CollectionFlattenProcPtr)(SInt32 size, void *data, void *refCon);
  153. typedef pascal OSErr (*CollectionExceptionProcPtr)(Collection c, OSErr status);
  154.  
  155. #if GENERATINGCFM
  156. typedef UniversalProcPtr CollectionFlattenUPP;
  157. typedef UniversalProcPtr CollectionExceptionUPP;
  158. #else
  159. typedef CollectionFlattenProcPtr CollectionFlattenUPP;
  160. typedef CollectionExceptionProcPtr CollectionExceptionUPP;
  161. #endif
  162.  
  163. enum {
  164.     uppCollectionFlattenProcInfo = kPascalStackBased
  165.          | RESULT_SIZE(SIZE_CODE(sizeof(OSErr)))
  166.          | STACK_ROUTINE_PARAMETER(1, SIZE_CODE(sizeof(SInt32)))
  167.          | STACK_ROUTINE_PARAMETER(2, SIZE_CODE(sizeof(void *)))
  168.          | STACK_ROUTINE_PARAMETER(3, SIZE_CODE(sizeof(void *))),
  169.     uppCollectionExceptionProcInfo = kPascalStackBased
  170.          | RESULT_SIZE(SIZE_CODE(sizeof(OSErr)))
  171.          | STACK_ROUTINE_PARAMETER(1, SIZE_CODE(sizeof(Collection)))
  172.          | STACK_ROUTINE_PARAMETER(2, SIZE_CODE(sizeof(OSErr)))
  173. };
  174.  
  175. #if GENERATINGCFM
  176. #define NewCollectionFlattenProc(userRoutine)        \
  177.         (CollectionFlattenUPP) NewRoutineDescriptor((ProcPtr)(userRoutine), uppCollectionFlattenProcInfo, GetCurrentArchitecture())
  178. #define NewCollectionExceptionProc(userRoutine)        \
  179.         (CollectionExceptionUPP) NewRoutineDescriptor((ProcPtr)(userRoutine), uppCollectionExceptionProcInfo, GetCurrentArchitecture())
  180. #else
  181. #define NewCollectionFlattenProc(userRoutine)        \
  182.         ((CollectionFlattenUPP) (userRoutine))
  183. #define NewCollectionExceptionProc(userRoutine)        \
  184.         ((CollectionExceptionUPP) (userRoutine))
  185. #endif
  186.  
  187. #if GENERATINGCFM
  188. #define CallCollectionFlattenProc(userRoutine, size, data, refCon)        \
  189.         CallUniversalProc((UniversalProcPtr)(userRoutine), uppCollectionFlattenProcInfo, (size), (data), (refCon))
  190. #define CallCollectionExceptionProc(userRoutine, c, status)        \
  191.         CallUniversalProc((UniversalProcPtr)(userRoutine), uppCollectionExceptionProcInfo, (c), (status))
  192. #else
  193. #define CallCollectionFlattenProc(userRoutine, size, data, refCon)        \
  194.         (*(userRoutine))((size), (data), (refCon))
  195. #define CallCollectionExceptionProc(userRoutine, c, status)        \
  196.         (*(userRoutine))((c), (status))
  197. #endif
  198. #endif
  199. #if FOR_SYSTEM8_PREEMPTIVE
  200. typedef OSStatus (*CollectionFlattenPreemptiveProcPtr)(ByteCount size, void *data, void *refCon);
  201. typedef OSStatus (*CollectionExceptionPreemptiveProcPtr)(Collection c, OSStatus status);
  202. #endif
  203. /*********************************************/
  204. /************* Public interfaces *************/
  205. /*********************************************/
  206. #if FOR_SYSTEM7_AND_SYSTEM8_PREEMPTIVE
  207. extern pascal Collection NewCollection(void )
  208.  TWOWORDINLINE(0x7000, 0xABF6);
  209.  
  210. extern pascal void DisposeCollection(Collection c)
  211.  TWOWORDINLINE(0x7001, 0xABF6);
  212.  
  213. extern pascal Collection CloneCollection(Collection c)
  214.  TWOWORDINLINE(0x7002, 0xABF6);
  215.  
  216. extern pascal SInt32 CountCollectionOwners(Collection c)
  217.  TWOWORDINLINE(0x7003, 0xABF6);
  218.  
  219. extern pascal Collection CopyCollection(Collection srcCollection, Collection dstCollection)
  220.  TWOWORDINLINE(0x7004, 0xABF6);
  221.  
  222. extern pascal SInt32 GetCollectionDefaultAttributes(Collection c)
  223.  TWOWORDINLINE(0x7005, 0xABF6);
  224.  
  225. extern pascal void SetCollectionDefaultAttributes(Collection c, SInt32 whichAttributes, SInt32 newAttributes)
  226.  TWOWORDINLINE(0x7006, 0xABF6);
  227.  
  228. extern pascal SInt32 CountCollectionItems(Collection c)
  229.  TWOWORDINLINE(0x7007, 0xABF6);
  230.  
  231. extern pascal OSErr AddCollectionItem(Collection c, CollectionTag tag, SInt32 id, SInt32 itemSize, void *itemData)
  232.  TWOWORDINLINE(0x7008, 0xABF6);
  233.  
  234. extern pascal OSErr GetCollectionItem(Collection c, CollectionTag tag, SInt32 id, SInt32 *itemSize, void *itemData)
  235.  TWOWORDINLINE(0x7009, 0xABF6);
  236.  
  237. extern pascal OSErr RemoveCollectionItem(Collection c, CollectionTag tag, SInt32 id)
  238.  TWOWORDINLINE(0x700A, 0xABF6);
  239.  
  240. extern pascal OSErr SetCollectionItemInfo(Collection c, CollectionTag tag, SInt32 id, SInt32 whichAttributes, SInt32 newAttributes)
  241.  TWOWORDINLINE(0x700B, 0xABF6);
  242.  
  243. extern pascal OSErr GetCollectionItemInfo(Collection c, CollectionTag tag, SInt32 id, SInt32 *index, SInt32 *itemSize, SInt32 *attributes)
  244.  TWOWORDINLINE(0x700C, 0xABF6);
  245.  
  246. extern pascal OSErr ReplaceIndexedCollectionItem(Collection c, SInt32 index, SInt32 itemSize, void *itemData)
  247.  TWOWORDINLINE(0x700D, 0xABF6);
  248.  
  249. extern pascal OSErr GetIndexedCollectionItem(Collection c, SInt32 index, SInt32 *itemSize, void *itemData)
  250.  TWOWORDINLINE(0x700E, 0xABF6);
  251.  
  252. extern pascal OSErr RemoveIndexedCollectionItem(Collection c, SInt32 index)
  253.  TWOWORDINLINE(0x700F, 0xABF6);
  254.  
  255. extern pascal OSErr SetIndexedCollectionItemInfo(Collection c, SInt32 index, SInt32 whichAttributes, SInt32 newAttributes)
  256.  TWOWORDINLINE(0x7010, 0xABF6);
  257.  
  258. extern pascal OSErr GetIndexedCollectionItemInfo(Collection c, SInt32 index, CollectionTag *tag, SInt32 *id, SInt32 *itemSize, SInt32 *attributes)
  259.  TWOWORDINLINE(0x7011, 0xABF6);
  260.  
  261. extern pascal Boolean CollectionTagExists(Collection c, CollectionTag tag)
  262.  TWOWORDINLINE(0x7012, 0xABF6);
  263.  
  264. extern pascal SInt32 CountCollectionTags(Collection c)
  265.  TWOWORDINLINE(0x7013, 0xABF6);
  266.  
  267. extern pascal OSErr GetIndexedCollectionTag(Collection c, SInt32 tagIndex, CollectionTag *tag)
  268.  TWOWORDINLINE(0x7014, 0xABF6);
  269.  
  270. extern pascal SInt32 CountTaggedCollectionItems(Collection c, CollectionTag tag)
  271.  TWOWORDINLINE(0x7015, 0xABF6);
  272.  
  273. extern pascal OSErr GetTaggedCollectionItem(Collection c, CollectionTag tag, SInt32 whichItem, SInt32 *itemSize, void *itemData)
  274.  TWOWORDINLINE(0x7016, 0xABF6);
  275.  
  276. extern pascal OSErr GetTaggedCollectionItemInfo(Collection c, CollectionTag tag, SInt32 whichItem, SInt32 *id, SInt32 *index, SInt32 *itemSize, SInt32 *attributes)
  277.  TWOWORDINLINE(0x7017, 0xABF6);
  278.  
  279. extern pascal void PurgeCollection(Collection c, SInt32 whichAttributes, SInt32 matchingAttributes)
  280.  TWOWORDINLINE(0x7018, 0xABF6);
  281.  
  282. extern pascal void PurgeCollectionTag(Collection c, CollectionTag tag)
  283.  TWOWORDINLINE(0x7019, 0xABF6);
  284.  
  285. extern pascal void EmptyCollection(Collection c)
  286.  TWOWORDINLINE(0x701A, 0xABF6);
  287.  
  288. #endif
  289. #if FOR_SYSTEM7_AND_SYSTEM8_COOPERATIVE
  290. extern pascal OSErr FlattenCollection(Collection c, CollectionFlattenUPP flattenProc, void *refCon)
  291.  TWOWORDINLINE(0x701B, 0xABF6);
  292.  
  293. extern pascal OSErr FlattenPartialCollection(Collection c, CollectionFlattenUPP flattenProc, void *refCon, SInt32 whichAttributes, SInt32 matchingAttributes)
  294.  TWOWORDINLINE(0x701C, 0xABF6);
  295.  
  296. extern pascal OSErr UnflattenCollection(Collection c, CollectionFlattenUPP flattenProc, void *refCon)
  297.  TWOWORDINLINE(0x701D, 0xABF6);
  298.  
  299. extern pascal CollectionExceptionUPP GetCollectionExceptionProc(Collection c)
  300.  TWOWORDINLINE(0x701E, 0xABF6);
  301.  
  302. extern pascal void SetCollectionExceptionProc(Collection c, CollectionExceptionUPP exceptionProc)
  303.  TWOWORDINLINE(0x701F, 0xABF6);
  304.  
  305. extern pascal Collection GetNewCollection(SInt16 collectionID)
  306.  TWOWORDINLINE(0x7020, 0xABF6);
  307.  
  308. #endif
  309. #if FOR_SYSTEM8_PREEMPTIVE
  310. extern OSStatus NewCollectionFromAllocator(MemAllocatorRef allocator, Collection *c);
  311.  
  312. extern OSStatus GetCollectionItemData(Collection c, CollectionTag tag, UInt32 id, ByteCount sizeAllowed, ByteCount *sizeReturned, void *itemData);
  313.  
  314. extern OSStatus GetIndexedCollectionItemData(Collection c, UInt32 index, ByteCount sizeAllowed, ByteCount *sizeReturned, void *itemData);
  315.  
  316. extern OSStatus GetTaggedCollectionItemData(Collection c, CollectionTag tag, UInt32 whichItem, ByteCount sizeAllowed, ByteCount *sizeReturned, void *itemData);
  317.  
  318. extern OSStatus GetFlattenedCollectionSize(Collection c, ByteCount *size);
  319.  
  320. extern OSStatus GetFlattenedPartialCollectionSize(Collection c, UInt32 whichAttributes, UInt32 matchingAttributes, ByteCount *size);
  321.  
  322. extern OSStatus FlattenCollectionToBuffer(Collection c, void *dataPtr, ByteCount sizeAllowed, ByteCount *sizeFlattened);
  323.  
  324. extern OSStatus FlattenPartialCollectionToBuffer(Collection c, UInt32 whichAttributes, UInt32 matchingAttributes, void *dataPtr, ByteCount sizeAllowed, ByteCount *sizeFlattened);
  325.  
  326. extern OSStatus UnflattenCollectionFromBuffer(Collection c, void *dataPtr, ByteCount size);
  327.  
  328. extern OSStatus FlattenCollectionPreemptive(Collection c, CollectionFlattenPreemptiveProcPtr flattenProc, void *refCon);
  329.  
  330. extern OSStatus FlattenPartialCollectionPreemptive(Collection c, CollectionFlattenPreemptiveProcPtr flattenProc, void *refCon, UInt32 whichAttributes, UInt32 matchingAttributes);
  331.  
  332. extern OSStatus UnflattenCollectionPreemptive(Collection c, CollectionFlattenPreemptiveProcPtr flattenProc, void *refCon);
  333.  
  334. extern CollectionExceptionPreemptiveProcPtr GetCollectionExceptionProcPreemptive(Collection c);
  335.  
  336. extern OSStatus SetCollectionExceptionProcPreemptive(Collection c, CollectionExceptionPreemptiveProcPtr exceptionProc);
  337.  
  338. #endif
  339. #if FOR_SYSTEM7_AND_SYSTEM8_DEPRECATED
  340. /**********************************************************************/
  341. /************** Utility routines for handle-based access **************/
  342. /**********************************************************************/
  343. extern pascal OSErr AddCollectionItemHdl(Collection aCollection, CollectionTag tag, SInt32 id, Handle itemData)
  344.  TWOWORDINLINE(0x7021, 0xABF6);
  345.  
  346. extern pascal OSErr GetCollectionItemHdl(Collection aCollection, CollectionTag tag, SInt32 id, Handle itemData)
  347.  TWOWORDINLINE(0x7022, 0xABF6);
  348.  
  349. extern pascal OSErr ReplaceIndexedCollectionItemHdl(Collection aCollection, SInt32 index, Handle itemData)
  350.  TWOWORDINLINE(0x7023, 0xABF6);
  351.  
  352. extern pascal OSErr GetIndexedCollectionItemHdl(Collection aCollection, SInt32 index, Handle itemData)
  353.  TWOWORDINLINE(0x7024, 0xABF6);
  354.  
  355. extern pascal OSErr FlattenCollectionToHdl(Collection aCollection, Handle flattened)
  356.  TWOWORDINLINE(0x7025, 0xABF6);
  357.  
  358. extern pascal OSErr UnflattenCollectionFromHdl(Collection aCollection, Handle flattened)
  359.  TWOWORDINLINE(0x7026, 0xABF6);
  360.  
  361. #endif
  362. #if OLDROUTINENAMES
  363.  
  364. enum {
  365.     dontWantTag                    = kCollectionDontWantTag,
  366.     dontWantId                    = kCollectionDontWantId,
  367.     dontWantSize                = kCollectionDontWantSize,
  368.     dontWantAttributes            = kCollectionDontWantAttributes,
  369.     dontWantIndex                = kCollectionDontWantIndex,
  370.     dontWantData                = kCollectionDontWantData
  371. };
  372.  
  373.  
  374. enum {
  375.     noCollectionAttributes        = kCollectionNoAttributes,
  376.     allCollectionAttributes        = kCollectionAllAttributes,
  377.     userCollectionAttributes    = kCollectionUserAttributes,
  378.     defaultCollectionAttributes    = kCollectionDefaultAttributes
  379. };
  380.  
  381.  
  382. enum {
  383.     collectionUser0Bit            = kCollectionUser0Bit,
  384.     collectionUser1Bit            = kCollectionUser1Bit,
  385.     collectionUser2Bit            = kCollectionUser2Bit,
  386.     collectionUser3Bit            = kCollectionUser3Bit,
  387.     collectionUser4Bit            = kCollectionUser4Bit,
  388.     collectionUser5Bit            = kCollectionUser5Bit,
  389.     collectionUser6Bit            = kCollectionUser6Bit,
  390.     collectionUser7Bit            = kCollectionUser7Bit,
  391.     collectionUser8Bit            = kCollectionUser8Bit,
  392.     collectionUser9Bit            = kCollectionUser9Bit,
  393.     collectionUser10Bit            = kCollectionUser10Bit,
  394.     collectionUser11Bit            = kCollectionUser11Bit,
  395.     collectionUser12Bit            = kCollectionUser12Bit,
  396.     collectionUser13Bit            = kCollectionUser13Bit,
  397.     collectionUser14Bit            = kCollectionUser14Bit,
  398.     collectionUser15Bit            = kCollectionUser15Bit,
  399.     collectionReserved0Bit        = kCollectionReserved0Bit,
  400.     collectionReserved1Bit        = kCollectionReserved1Bit,
  401.     collectionReserved2Bit        = kCollectionReserved2Bit,
  402.     collectionReserved3Bit        = kCollectionReserved3Bit,
  403.     collectionReserved4Bit        = kCollectionReserved4Bit,
  404.     collectionReserved5Bit        = kCollectionReserved5Bit,
  405.     collectionReserved6Bit        = kCollectionReserved6Bit,
  406.     collectionReserved7Bit        = kCollectionReserved7Bit,
  407.     collectionReserved8Bit        = kCollectionReserved8Bit,
  408.     collectionReserved9Bit        = kCollectionReserved9Bit,
  409.     collectionReserved10Bit        = kCollectionReserved10Bit,
  410.     collectionReserved11Bit        = kCollectionReserved11Bit,
  411.     collectionReserved12Bit        = kCollectionReserved12Bit,
  412.     collectionReserved13Bit        = kCollectionReserved13Bit,
  413.     collectionPersistenceBit    = kCollectionPersistenceBit,
  414.     collectionLockBit            = kCollectionLockBit
  415. };
  416.  
  417.  
  418. enum {
  419.     collectionUser0Mask            = kCollectionUser0Mask,
  420.     collectionUser1Mask            = kCollectionUser1Mask,
  421.     collectionUser2Mask            = kCollectionUser2Mask,
  422.     collectionUser3Mask            = kCollectionUser3Mask,
  423.     collectionUser4Mask            = kCollectionUser4Mask,
  424.     collectionUser5Mask            = kCollectionUser5Mask,
  425.     collectionUser6Mask            = kCollectionUser6Mask,
  426.     collectionUser7Mask            = kCollectionUser7Mask,
  427.     collectionUser8Mask            = kCollectionUser8Mask,
  428.     collectionUser9Mask            = kCollectionUser9Mask,
  429.     collectionUser10Mask        = kCollectionUser10Mask,
  430.     collectionUser11Mask        = kCollectionUser11Mask,
  431.     collectionUser12Mask        = kCollectionUser12Mask,
  432.     collectionUser13Mask        = kCollectionUser13Mask,
  433.     collectionUser14Mask        = kCollectionUser14Mask,
  434.     collectionUser15Mask        = kCollectionUser15Mask,
  435.     collectionReserved0Mask        = kCollectionReserved0Mask,
  436.     collectionReserved1Mask        = kCollectionReserved1Mask,
  437.     collectionReserved2Mask        = kCollectionReserved2Mask,
  438.     collectionReserved3Mask        = kCollectionReserved3Mask,
  439.     collectionReserved4Mask        = kCollectionReserved4Mask,
  440.     collectionReserved5Mask        = kCollectionReserved5Mask,
  441.     collectionReserved6Mask        = kCollectionReserved6Mask,
  442.     collectionReserved7Mask        = kCollectionReserved7Mask,
  443.     collectionReserved8Mask        = kCollectionReserved8Mask,
  444.     collectionReserved9Mask        = kCollectionReserved9Mask,
  445.     collectionReserved10Mask    = kCollectionReserved10Mask,
  446.     collectionReserved11Mask    = kCollectionReserved11Mask,
  447.     collectionReserved12Mask    = kCollectionReserved12Mask,
  448.     collectionReserved13Mask    = kCollectionReserved13Mask,
  449.     collectionPersistenceMask    = kCollectionPersistenceMask,
  450.     collectionLockMask            = kCollectionLockMask
  451. };
  452.  
  453. #endif
  454.  
  455. #if PRAGMA_ALIGN_SUPPORTED
  456. #pragma options align=reset
  457. #endif
  458.  
  459. #if PRAGMA_IMPORT_SUPPORTED
  460. #pragma import off
  461. #endif
  462.  
  463. #ifdef __cplusplus
  464. }
  465. #endif
  466.  
  467. #endif /* __COLLECTIONS__ */
  468.  
  469.